package com.wondream.jenkins.event;

import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.context.ApplicationEvent;

import java.util.Map;

public class JenkinsEvent extends ApplicationEvent {

    private String eventType;

    private Object data;

    private Map<String, Object> dataMap;

    public JenkinsEvent(Object source) {
        super(source);
    }

    public JenkinsEvent(Object source, String eventType, Object data, Map<String, Object> dataMap) {
        super(source);
        this.eventType = eventType;
        this.data = data;
        this.dataMap = dataMap;
    }

    public String getEventType() {
        return eventType;
    }

    public void setEventType(String eventType) {
        this.eventType = eventType;
    }

    public Object getData() {
        return data;
    }

    public void setData(Object data) {
        this.data = data;
    }

    public Map<String, Object> getDataMap() {
        return dataMap;
    }

    public void setDataMap(Map<String, Object> dataMap) {
        this.dataMap = dataMap;
    }
}